import os
file_names = os.listdir("data")



all_data = ""
for file in file_names:
    data = open("data/{}".format(file),"r")
    all_data += data.read()
data.close()
#写入
with open("data/1.txt","w+") as f:
    f.write(all_data)
    f.close()
